package top.kaoshanji.p1ch10c;

/**
 * 代码清单-p1ch10c-229页b：使用默认方法
 * author kaoshanji
 * ^_^
 * create time 2025/3/10 17:54
 */
public class Implementation2 implements InterfaceWithDefault {

    @Override
    public void firstMethod() {
        System.out.println("firstMethod");
    }

    @Override
    public void secondMethod() {
        System.out.println("secondMethod");
    }

    public static void main(String[] args) {

        InterfaceWithDefault i = new Implementation2();

        i.firstMethod();
        i.secondMethod();
        i.newMethod();

    }

}
